//#define __FORCE_TRACE__
//#define __FORCE_DEBUG__
//#define __FORCE_INFO__
#define THIS_FILE "fn_applyMediKit.sqf"
#include <btc_macros.h>
TRACE_1("Start",_this);


	BTC_r_action_menu = false;
	if (!isNull BTC_r_unit_dlg) then
	{
		private ["_unit","_cpr_bonus","_name"];
		_unit = BTC_r_unit_dlg;
		closeDialog 0;
		player playMove "AinvPknlMstpSnonWnonDr_medic0";//CPR
		_cpr_bonus = BTC_r_cpr_time / 10;
		_name = name _unit;
		BTC_cpr_pveh = [7,_name,_cpr_bonus];publicVariable "BTC_cpr_pveh";
		sleep 7;
		player playMove "AinvPknlMstpSnonWnonDr_medic0";
		sleep 7;
		if (!isNull _unit && _unit getVariable "BTC_need_revive" == 1 && _unit != player && !BTC_r_unc_loop) then
		{
			_cpr_bonus = BTC_r_cpr_time - (BTC_r_cpr_time / 10);
			BTC_cpr_pveh = [7,_name,_cpr_bonus];publicVariable "BTC_cpr_pveh";
		};
	};
	BTC_r_action_menu = true;
